<eda-dialog [inject]="dialog">
    <div body>


        <form [formGroup]="form">
            <div class="grid">
                <div class="col-12 lg:col-6">
                    <label i18n="@@inputNombre">Nombre *</label>
                    <input pInputText formControlName="name" class="w-100" type="text" i18n-placeholder="@@inputNombre"
                        placeholder="Nombre" required />
                </div>
                <div class="col-12 lg:col-6">
                    <label i18n="@@inputEmail">Correo *</label>
                    <input pInputText formControlName="email" class="w-100" type="email" i18n-placeholder="@@inputEmail"
                        placeholder="Correo" autocomplete="username" required />
                </div>
                <div class="col-12 lg:col-6">
                    <label i18n="@@inputPassword">Contraseña *</label>
                    <input pInputText formControlName="password" class="w-100" type="password"
                        i18n-placeholder="@@inputPassword" placeholder="Contraseña" autocomplete="new-password"
                        required />
                </div>
                <div class="col-12 lg:col-6">
                    <label i18n="@@inputSeguridad">Seguridad *</label>
                    <input pInputText formControlName="rpassword" class="w-100" type="password"
                        i18n-placeholder="@@inputRepitePassword" i18n-placeholder="@@newPassPlaceholderUsers"
                        placeholder="Repite la contraseña" autocomplete="new-password" required />
                </div>
                <div *ngIf="controller.params.id" class="col-12 lg:col-6">
                </div>
                <div class="col-12">
                    <label i18n="@@inputGrupo">Grupo *</label>
                    <div>
                        <p-selectButton [options]="roles" formControlName="role" optionLabel="name" multiple="multiple">
                        </p-selectButton>
                    </div>
                </div>
            </div>
        </form>
    </div>
    <div footer>
        <div class="ui-dialog-buttonpane ui-widget-content ui-helper-clearfix text-right">
            <button type="button" pButton (click)="saveUser()" class="p-button-raised p-button-success"
                i18n-label="@@guardarBtn" [label]="btnLabel"></button>
            <button type="button" pButton (click)="closeDialog()" class="p-button-raised p-button-danger"
                i18n-label="@@cerrarBtn" label="Cerrar"></button>
        </div>
    </div>

</eda-dialog>